package com.xiaochong.tir.apiservice.component.mqsend;

import org.springframework.amqp.core.AmqpTemplate;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

import com.xc.logclient.utils.LogTrace;

/**
 * Created by org on 2018/6/11.
 * 发送消费
 */
@Component
public class MqBinanceSendConponent {

    @Autowired
    private AmqpTemplate rabbitTemplatenew;

    public void mqSend(String queen,String data){
        LogTrace.beginTrace("开始分发路由队列");
        try {
            rabbitTemplatenew.convertAndSend(queen, data);
        }catch (Exception e){
            e.printStackTrace();
            LogTrace.error("开始分发路由队列",e);
        }
    }
}

